package com.great.springbootelkdemo;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestController {

    Logger logger = LoggerFactory.getLogger(TestController.class);


    @RequestMapping("/cs")
    public String cs(){
        logger.info("测试log");
        for(int i = 0; i < 30; i++){
            logger.error("something wrong. id={}; name=Ryan-{};", i, i);
        }
        return "测试";
    }
}